{% extends "_layouts/default.html" %}

{% block content %}
<div class="post">
	<header class="post-header">
		<h1 class="post-title">{{ blog.title }} {% if blog.top != 0 %}<span class="top">[置顶]</span>{% endif %}</h1>
		<p class="post-meta">{{ blog.date | date('Y-m-d') }}{% if blog.author %} • {{ blog.author }}{% endif %}{% if blog.keywords %} • {{ blog.keywords | join(',') }}{% endif %}</p>
	</header>
	<article class="post-content">
		{{ blog.content | raw }}
	</article>
	
	{% if site.duoshuo %}
	<div class="post-content">
		<!-- 多说评论框 start -->
		<div class="ds-thread" data-thread-key="{{ blog.blogId }}" data-title="{{ blog.title }}" data-url="{{ site.url }}{{ blog.siteURL }}"></div>
		<!-- 多说评论框 end -->
		<!-- 多说公共JS代码 start (一个网页只需插入一次) -->
		<script type="text/javascript">
		var duoshuoQuery = {short_name:"{{ site.duoshuo }}"};
		(function() {
			var ds = document.createElement('script');
			ds.type = 'text/javascript';ds.async = true;
			ds.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') + '//static.duoshuo.com/embed.js';
			ds.charset = 'UTF-8';
			(document.getElementsByTagName('head')[0] 
			 || document.getElementsByTagName('body')[0]).appendChild(ds);
		})();
		</script>
        <!-- 多说公共JS代码 end -->
	</div>
	{% endif %}
</div>
{% endblock %}